package com.hermit.qmst.UI.activity;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.hermit.qmst.R;

/**
 * Created by hermithermit on 15/2/18.
 */
public class ExplainDetailActivity extends Activity implements View.OnClickListener{

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        setContentView(R.layout.activity_explain_detail);
        initView();
    }

    private void initView(){

        Intent intent = getIntent();
        String title = intent.getStringExtra("title");

        ((TextView) findViewById(R.id.tv_title)).setText(title);
        ((ImageView)findViewById(R.id.iv_title_left)).setImageResource(R.drawable.ic_back);
        findViewById(R.id.iv_title_left).setOnClickListener(this);

    }

    @Override
    public void onClick(View v) {

        switch (v.getId()){

            case R.id.iv_title_left:
                ExplainDetailActivity.this.finish();
                break;
        }

    }
}
